package com.igeek.compus.backend.user.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.util.Date;

@Data
public class User {

    private int id;

    // 小程序唯一用户id
    private String openId;

    private String nickName;

    private String sex;

    private String phone;

    private Integer age;

    private String email;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date lastTime;

    // 状态：0-正常 1-异常
    private Integer status;

    // 是否为卖家：0-不是 1-是
    private Integer isSeller;

    // 最小单位分
    private Integer integral;

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", nickName='" + nickName + '\'' +
                ", sex='" + sex + '\'' +
                ", phone='" + phone + '\'' +
                ", age=" + age +
                ", email='" + email + '\'' +
                ", createTime=" + createTime +
                ", lastTime=" + lastTime +
                ", status=" + status +
                '}';
    }
}
